<script setup>
import { ref } from 'vue';
const user = ref({})
</script>

<template>
  <div class="container">
    <div class="main">
      <div class="login-left">
        <img src="@/assets/login/login2.jpg" alt="login">
      </div>
      <div class="login-right">
        <el-form :model="user">
          <div class="form-title">欢迎登录后台管理系统</div>
          <el-form-item prop="username"><el-input placeholder="请输入账号" v-model="user.username"></el-input></el-form-item>
          <el-form-item prop="pwd"><el-input placeholder="请输入密码" show-password v-model="user.pwd"></el-input></el-form-item>
          <el-form-item prop="validCode">
            <div style="display: flex;">
              <el-input style="flex:1"></el-input>
              <div style="flex:1;">1232</div>
            </div>
          </el-form-item>
          <el-form-item><el-button type="primary" style="width:100%;">登录</el-button></el-form-item>
          <div style="display: flex;">
            <div style="flex:1">还没有账号?请<span style="color:#0f9876;cursor: pointer;">注册</span></div>
            <div style="flex:1;text-align: right;"><span style="color:#0f9876;cursor: pointer;">忘记密码</span></div>
          </div>
        </el-form>
      </div>
    </div>
  </div>
</template>
<style scoped>
.container{
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #0f9876;
}
.main{
  display: flex;
  background-color: white;
  width: 50%;
  border-radius: 5px;
  overflow: hidden;
}
.login-left{
  flex:1;
}
.login-right{
  flex:1;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: yellow;
}
.el-form{
  widows: 80%;
}
.form-title{
  font-size: 20px;
  font-weight: bold;
  text-align: center;
  margin-bottom: 20px;
}
.el-icon{
  flex:1;
}
el-input{
  flex:1;
}
</style>